* {
  box-sizing: border-box;

  &::before,
  &::after {
    box-sizing: border-box;
  }
}

.animate__animated {
  &.animate__bounce {
    --animate-duration: 1s
  }
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px
}

::-webkit-scrollbar-track {
  border-radius: 10px
}

::-webkit-scrollbar-thumb {
  border-radius: 10px;
  background-color: #aaa
}

::-webkit-scrollbar-thumb:window-inactive {
  background-color: #aaa
}

::placeholder {
  color: #333 !important
}

.btn-check:disabled+.btn, 
.btn-check[disabled]+.btn
.btn-primary.disabled, 
.btn-primary:disabled {
  filter: grayscale(1);
}

html {
  font-size: 14px;
  height: 100%
}

body {
  font-size: 1rem;
  height: 100%
}

.body {
  padding: 10px;
  height: 100%;
  display: flex;
  flex-direction: column
}

.header {
  margin: 0 0 10px;
  display: flex;
  align-items: center;

  img {
    margin-right: 10px
  }
}

.footer {
  font-size: 1.3rem;
  font-weight: normal
}

select {
  width: 100%
}

.form {
  height: 100%;
  border: 3px solid #1cbb8c;
  padding: 10px;
  overflow: auto;

  label {
    display: block;
    margin: 15px 0 10px
  }

  h3 {
    margin-top: 30px;

    &:nth-child(1) {
      margin-top: 20px
    }
  }

  .btn-group {
    label {
      margin: 0
    }
  }
}

.show {
  display: block !important
}

.visible {
  visibility: visible
}

#manual-mode {
  display: none;
  padding: 10px
}

.red {
  color: red
}

.time,
.item {
  display: inline-flex;
  align-items: center;

  &:not(:nth-child(1)) {
    margin-left: 20px
  }

  label {
    margin-right: 5px;

    &:nth-child(1) {
      font-weight: 600
    }

    &:not(:nth-child(1)) {
      margin-left: 5px
    }
  }

  select {
    width: 165px;

    & ~ * {
      visibility: hidden
    }
  }

  input {
    width: 90px
  }
}

#radar {
  width: 150px
}

.submit {
  text-align: center;
  margin: 40px 0 20px
}

#dialog {
  text-align: center;
  border: 1px solid #ccc;
  border-radius: 5px;
  box-shadow: 0 0 5px 5px #ccc;
  position: absolute;
  z-index: 2;
  left: 0;
  top: 20px;
  margin: 0 auto;

  .dialog-content {
    display: flex;
    align-items: center
  }

  p {
    font-size: 1.3rem;
    margin-bottom: 0;
    margin-right: 10px
  }
}

.block-item {
  display: flex;

  & > div:nth-child(1) {
    text-align: center;
    margin-right: 60px;
    width: 250px;
    position: relative;

    &::after {
      content: "";
      display: block;
      position: absolute;
      width: 1px;
      background-color: #ccc;
      height: 80%;
      right: 0;
      top: 50%;
      transform: translateY(-50%)
    }
  }
}


.tempSize {
  font-size: 4.7rem
}

.port-title {
  display: flex;
  align-items: center;
  margin: 30px 0 10px;
  flex-wrap: wrap;

  h3 {
    color: #3b7ddd;
    margin: 0 !important;
    white-space: nowrap
  }

  .form-switch {
    margin: 0 0 0 calc(100% - 80px);
  }

  .form-switch {
    label {
      margin: 0
    }
  }

  .red {
    width: 100%
  }
}

.port-width {
  display: flex;

  label {
    white-space: nowrap
  }

  input {
    width: 200px;
    margin-left: 10px
  }
}

.backauto {
  display: inline-flex;
  align-items: center;
  margin-bottom: 0;

  label {
    display: inline-flex;
    align-items: center
  }

  input {
    width: 100px
  }
}

.item {
  &.full-width {
    width: 100%;

    & > label {
      margin: 0
    }
  }

  &.pwd {
    label {
      font-weight: normal
    }
  }

  input {
    width: 150px
  }

}

#areaDevice {
  margin-bottom: 20px
}

.margin-left-0 {
  margin-left: 0 !important
}

.cooldown {
  margin-top: 20px
}

.none {
  display: none !important
}

.week,
.port1,
.port2,
.cooldown,
.radar,
.backautobox,
.Temperature,
.humidity,
.screensaver {
  display: none
}

.cooldown,
.radar,
.Temperature,
.humidity,
.screensaver {
  &.show {
    display: inline-flex !important
  }
}

#loading {
  z-index: 20;
  opacity: 0.5;
}

@media screen and (max-width: 600px) {
  .block-item {
    display: block;

    & > div:nth-child(1) {

      &::after {
        display: none;
      }
    }
  }

  .time {
    display: block;

    label {
      display: inline-block;
      width: 50px;
      margin-left: 0 !important;

      &:nth-last-child(2) {
        width: 30px;
      }
    }

    select {
      width: calc(100% - 60px);
    }

    input {
      width: calc((100% - 110px) / 2 + 3px);
    }

    select,
    input {
      display: inline-block;
    }
  }
}


// login
#bg {
  background-image: url(//api.nevegy.com/uploads/dashboards/nevegy.png);
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center top;
  min-height: 100%;
  height: 100%;
  overflow: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

#loginPage {
  max-width: 300px;
  font-size: 12px;

  ul {
    list-style-type: none;
  }

  input {
    color: #333 !important;

    &:-internal-autofill-previewed,
    &:-internal-autofill-selected {
      transition: background-color 5000s ease-in-out 0s !important;
    }
    &:-webkit-autofill {
      -webkit-box-shadow: 0 0 0px 1000px white inset;
    }
  }
}

.form-control {
  display: block;
  width: 100%;
  padding: .375rem .75rem;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--bs-body-color);
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-color: #fff;
  background-clip: padding-box;
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
  font-family: sans-serif, system-ui, -apple-system !important;
  margin: 0;
}

#loginLogo {
  margin: 40px 0 30px;
  max-width: 100%;
}

#loginTitle {

  h1 {
    font-size: 2rem;
    font-weight: 400;
    line-height: 32px;
    font-family: Roboto, sans-serif;
    letter-spacing: normal;
    margin: 0 0 16px;
    color: #666;
  }

  p {
    margin: 0 0 12px;
  }
}

#loginSubmitBox {
  margin-top: 20px;

  a {
    cursor: pointer;
  }
}

#loginSubmit {
  background-color: #3b7cdc;
  color: #fff;
  height: 36px;
  border-radius: 4px;
  padding: 0 16px 0 16px;
  border: none;
  outline: none;
}
